package com.sankei;

import com.sankei.rocketmq.ProducerService;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.context.ConfigurableApplicationContext;

@SpringBootApplication
public class ProducerSpringBootApplication
{
    public static void main( String[] args )
    {
        ConfigurableApplicationContext run = SpringApplication.run(ProducerSpringBootApplication.class, args);
        ProducerService producer = (ProducerService) run.getBean("producerService");
        producer.sendMessage();
        System.out.println("Send Success");
    }
}
